// Copyright (C) ZHENG Zhong <heavyzheng nospam-at gmail D0T com>
//
// $Id: basis.hpp 225 2008-09-12 17:43:02Z heavyzheng $
//

#ifndef ZZHENG_QUANT_DATES_BASIS_HPP_20080808__
#define ZZHENG_QUANT_DATES_BASIS_HPP_20080808__

#include <zzheng/quant/dates/config.hpp>
#include <string>

namespace zzheng {
namespace quant {
namespace dates {

    //! The basis (day count convention) enumerations.
    enum basis_t {

        unknown_basis = 0,
        // actual_252,
        actual_360,
        actual_365,
        // actual_365_fixed,
        // actual_365_japan,
        // actual_365L,
        actual_actual,
        bma_30_360,
        // E30Plus360,
        french_30_360,
        isda_30_360,
        isda_30e_360,
        isda_actual_actual,
        // ISMA30E360,
        // ISMAActualActual,
        // Italian30360,
        // PriceBasis,
        // SIA30360,
        // SIAActual360,
        // SIAActualActual,

    }; // enum basis_t

    inline
    std::string to_string(basis_t basis) {
        switch (basis) {
        case actual_360:
            return "Actual/360";
        case actual_365:
            return "Actual/365";
        default:
            return "Unknown";
        }
    }

} // namespace zzheng::quant::dates
} // namespace zzheng::quant
} // namespace zzheng

#endif // ZZHENG_QUANT_DATES_BASIS_HPP_20080808__


